package com.backend.entity;

import com.baomidou.mybatisplus.annotation.*;

import java.io.Serializable;
import java.util.Date;
import lombok.Data;

/**
 * 用户表
 * @TableName user
 */
@TableName(value ="user")
@Data
public class User implements Serializable {
    /**
     * 主键
     */
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    /**
     * 账号
     */
    @TableField(value = "userName")
    private String userName;

    /**
     * 密码
     */
    @TableField(value = "userPassword")
    private String userPassword;

    /**
     * 角色（user：用户；admin：管理员）
     */
    @TableField(value = "userRole")
    private String userRole;

    /**
     * 简介
     */
    @TableField(value = "userProfile")
    private String userProfile;

    /**
     * 头像地址
     */
    @TableField(value = "userAvatar")
    private String userAvatar;

    /**
     * 昵称
     */
    @TableField(value = "nickName")
    private String nickName;

    /**
     * 性别
     */
    @TableField(value = "userSex")
    private String userSex;

    /**
     * 邮箱
     */
    @TableField(value = "userEmail")
    private String userEmail;

    /**
     * 身份证
     */
    @TableField(value = "userCredit")
    private String userCredit;

    /**
     * 更新时间
     */
    @TableField(value = "createTime")
    private Date createTime;

    /**
     * 更新时间
     */
    @TableField(value = "updateTime")
    private Date updateTime;

    /**
     * 逻辑删除（0：不删除；1：删除）
     */
    @TableLogic
    @TableField(value = "isDelete")
    private Byte isDelete;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;
}